package cn.tedu.abstractx;

public abstract class Pet {
    String name;
    int age;
    //构造方法 -- 为了子类调用
    public Pet(){
        System.out.println("Pet 的构造方法");
    }
    //抽象方法
    public abstract void eat();
//    public abstract static void eat();
//    public void eat() {
//    }
//    public abstract void call();
    public void sleep(){
        System.out.println("睡");
    }
}

class Dog extends Pet{
    @Override
    public void eat() {
        System.out.println("狗刨骨头  吃~");
    }
}
class Cat extends Pet{
    @Override
    public void eat() {
        System.out.println("猫抓鱼  吃~");
    }
}
abstract class A{

}
class Bird extends Pet{

    @Override
    public void eat() {

    }
}
//abstract class Bird extends Pet{
//    @Override
//    public void eat() {
//
//    }
//}
//class ABird extends Bird{
//
//}
